home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1998 January / EnigmA AMIGA RUN 24 (1997)(G.R. Edizioni)(IT)[!][issue 1998-01 & 02].iso / EARCD / UTILI2 / TragicWB / Install_TragicWB next >
Text File  |  1997-08-08  |  3KB  |  124 lines

  1. (
  2.     (set #dest
  3.     (askdir
  4.         (prompt "Select the directory to install TragicWB to:")
  5.         (help @askdir-help)
  6.         (default "C:")
  7.     )
  8.     )
  9.  
  10.     (set @default-dest #dest)
  11.  
  12.     (set #startup
  13.     (or
  14.         (= @user-level 0)
  15.         (askbool
  16.         (prompt "Do you want TragicWB to start when you boot your Amiga?")
  17.         (help "If you answer Yes, TragicWB will be added to your "
  18.               "user-startup file, so it will start automatically "
  19.               "when you switch on or reboot your Amiga. If you "
  20.               "answer No, you will have to start TragicWB "
  21.               "from a CLI, which isn't very convenient and "
  22.               "may not work at all.")
  23.         )
  24.     )
  25.     )
  26.  
  27.     (set #installpal
  28.     (or
  29.         (= @user-level 0)
  30.         (askbool
  31.         (prompt "Do you want to use the Magic Workbench palette?")
  32.         (help "If you answer Yes, your palette preferences will "
  33.               "be set to the Magic Workbench  colour scheme. If you answer "
  34.               "No, then your palette will not be changed, and "
  35.               "old-style Magic Workbench icons will still have the wrong "
  36.               "colours.")
  37.         )
  38.     )
  39.     )
  40.  
  41.     (set #depth "")
  42.  
  43.     (if (> @user-level 0)
  44.     (
  45.         (set #depth_opt
  46.         (askchoice
  47.             (prompt "When should TragicWB obtain pens for the standard "
  48.             "NewIcons colours?")
  49.             (help "If you don't use NewIcons or don't want to change "
  50.             "the way NewIcons dynamically allocates pens, answer "
  51.             "\"Never\". Otherwise choose how the minimum number "
  52.             "of colours on the Workbench screen for TragicWB "
  53.             "to allocate NewIcons pens. I'd suggest choosing "
  54.             "32 or 64 colours, as preferences plus MagicWB "
  55.             "plus NewIcons colours gives a total of 22 pens.")
  56.             (choices
  57.             "pNever"
  58.             "When WB has 16 or more colours"
  59.             "When WB has 32 or more colours"
  60.             "When WB has 64 or more colours"
  61.             "When WB has 128 or more colours"
  62.             "When WB has 256 or more colours")
  63.         )
  64.         )
  65.         (if (> #depth_opt 0)
  66.         (set #depth (" NEWICONSDEPTH=%ld" (+ #depth_opt 3)))
  67.         )
  68.     )
  69.     )
  70.  
  71.     (set #startnow
  72.     (or
  73.         (= @user-level 0)
  74.         (askbool
  75.         (prompt "Do you want to start TragicWB now?")
  76.         (help "If you answer Yes, TragicWB will be started as "
  77.               "soon as it has been installed. If you answer "
  78.               "No, it will not start until you reboot or run "
  79.               "it from a CLI.")
  80.         )
  81.     )
  82.     )
  83.  
  84.     (complete 20)
  85.  
  86. ; Don't blame me for this. Tf the user chooses to start TragicWB
  87. ; now, I must do (run "TragicWB" ...). But I must also copy
  88. ; MWB-palette.pre to env:sys/, if the user chose to do that as
  89. ; well. So I have to ask in advance and then perform actions
  90. ; based on two questions without re-prompting - which would be stupid.
  91. ; If anyone can tell me a better way to do this, I'll use it in future.
  92.  
  93.     (set @user-level 0)
  94.  
  95.     (copyfiles (source "TragicWB") (dest #dest) (prompt "") (help ""))
  96.  
  97.     (complete 40)
  98.  
  99.     (if #startup
  100.     (startup @app-name
  101.         (command (cat (tackon #dest "TragicWB") #depth))
  102.         (prompt "") (help "")
  103.     )
  104.     )
  105.  
  106.     (if #installpal
  107.     (copyfiles (source "MWB-palette.pre") (dest "envarc:sys") (newname "palette.prefs") (prompt "") (help ""))
  108.  
  109.     (complete 60)
  110.  
  111.     (if #startnow
  112.         (copyfiles (source "MWB-palette.pre") (dest "env:sys") (newname "palette.prefs") (prompt "") (help ""))
  113.     )
  114.     )
  115.  
  116.     (complete 80)
  117.  
  118.     (if #startnow
  119.     (run (cat (tackon #dest "TragicWB") #depth) (prompt "") (help ""))
  120.     )
  121.  
  122.     (complete 100)
  123. )
  124.